package aer.LlenandoPiscinas;

import java.io.*;
import java.util.*;

public class LlenandoPiscinas {
	private static StringTokenizer st;
	private static PrintWriter out = new PrintWriter(System.out);
	private static BufferedReader br = new BufferedReader(
			new InputStreamReader(System.in));
	private static int miPiscina, miBarrenyo, miPerdida, suPiscina, suBarrenyo,
			suPerdida;

	public static void main(String[] args) throws Exception {

		lectura();
		while (miPiscina > 0 && suPiscina > 0) {
			programa();
			lectura();
		}
		out.flush();

	}

	private static int calcular(int piscina, int barrenyo, int perdida) {

		if (barrenyo >= piscina) {
			return 1;
		} else if (barrenyo <= perdida) {
			return 0;
		} else {
			int n1 = (piscina - perdida);
			int n2 = (barrenyo - perdida);
			int sol = n1 / n2;
			int resto = n1 % n2;
			if (resto > 0) {
				sol++;
			}

			return sol;
		}
	}

	private static void programa() {
		int vYo = calcular(miPiscina, miBarrenyo, miPerdida);
		int vVecino = calcular(suPiscina, suBarrenyo, suPerdida);

		if (vYo == vVecino) {
			out.print("EMPATE " + vYo + "\n");
		} else if (vYo == 0) {
			out.print("VECINO " + vVecino + "\n");
		} else if (vVecino == 0) {
			out.print("YO " + vYo + "\n");
		} else if (vYo < vVecino) {
			out.print("YO " + vYo + "\n");
		} else { // vVecino < vYo
			out.print("VECINO " + vVecino + "\n");
		}

	}

	private static int readInt() {
		return Integer.parseInt(st.nextToken());
	}

	private static void lectura() throws Exception {
		st = new StringTokenizer(br.readLine());

		miPiscina = readInt();
		miBarrenyo = readInt();
		miPerdida = readInt();

		suPiscina = readInt();
		suBarrenyo = readInt();
		suPerdida = readInt();
	}

}